using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._3DAnalystTools._TINDataset._Conversion
{
    /// <summary>
    /// <para>LandXML To TIN</para>
    /// <para>This tool imports one or more triangulated irregular network (TIN) surfaces from a LandXML file to output Esri TINs.</para>
    /// <para>此工具从 LandXML 文件导入一个或多个三角化不规则网络 （TIN） 表面以输出 Esri TIN。</para>
    /// </summary>    
    [DisplayName("LandXML To TIN")]
    public class LandXMLToTin : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public LandXMLToTin()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_landxml_path">
        /// <para>Input</para>
        /// <para>The input LandXML file.</para>
        /// <para>输入 LandXML 文件。</para>
        /// </param>
        /// <param name="_out_tin_folder">
        /// <para>Output TIN Folder</para>
        /// <para>The folder that the output TINs will be created in.</para>
        /// <para>将在其中创建输出 TIN 的文件夹。</para>
        /// </param>
        /// <param name="_tin_basename">
        /// <para>Output TIN Base Name</para>
        /// <para>The basename of the resulting TIN. When several TINs will be exported from the LandXML file, the basename is used to define a unique name for each output TIN. If <basename> already exists, the tool will not write anything. If <basename> does not exist but <basename>2 exists, the tool will create <basename> and <basename>2_1, instead of <basename>2.</para>
        /// <para>生成的 TIN 的基名。当将从 LandXML 文件导出多个 TIN 时，基名用于为每个输出 TIN 定义唯一名称。如果<basename>已存在，则该工具不会写入任何内容。如果<basename>不存在但存在 <basename>2，则工具将创建 <basename> <basename>2_1，而不是 <basename>2。</para>
        /// </param>
        public LandXMLToTin(object _in_landxml_path, object _out_tin_folder, object _tin_basename)
        {
            this._in_landxml_path = _in_landxml_path;
            this._out_tin_folder = _out_tin_folder;
            this._tin_basename = _tin_basename;
        }
        public override string ToolboxName => "3D Analyst Tools";

        public override string ToolName => "LandXML To TIN";

        public override string CallName => "3d.LandXMLToTin";

        public override List<string> AcceptEnvironments => ["scratchWorkspace", "tinSaveVersion", "workspace"];

        public override object[] ParameterInfo => [_in_landxml_path, _out_tin_folder, _tin_basename, _tinnames, _derived_tin_folder];

        /// <summary>
        /// <para>Input</para>
        /// <para>The input LandXML file.</para>
        /// <para>输入 LandXML 文件。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_landxml_path { get; set; }


        /// <summary>
        /// <para>Output TIN Folder</para>
        /// <para>The folder that the output TINs will be created in.</para>
        /// <para>将在其中创建输出 TIN 的文件夹。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output TIN Folder")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _out_tin_folder { get; set; }


        /// <summary>
        /// <para>Output TIN Base Name</para>
        /// <para>The basename of the resulting TIN. When several TINs will be exported from the LandXML file, the basename is used to define a unique name for each output TIN. If <basename> already exists, the tool will not write anything. If <basename> does not exist but <basename>2 exists, the tool will create <basename> and <basename>2_1, instead of <basename>2.</para>
        /// <para>生成的 TIN 的基名。当将从 LandXML 文件导出多个 TIN 时，基名用于为每个输出 TIN 定义唯一名称。如果<basename>已存在，则该工具不会写入任何内容。如果<basename>不存在但存在 <basename>2，则工具将创建 <basename> <basename>2_1，而不是 <basename>2。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output TIN Base Name")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _tin_basename { get; set; }


        /// <summary>
        /// <para>TINs to Import</para>
        /// <para>The one or more LandXML TIN surfaces that will be exported to an Esri TIN.</para>
        /// <para>将导出到 Esri TIN 的一个或多个 LandXML TIN 图面。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("TINs to Import")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public List<object> _tinnames { get; set; } = null;


        /// <summary>
        /// <para>Updated Output TIN Folder</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Updated Output TIN Folder")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _derived_tin_folder { get; set; }


        public LandXMLToTin SetEnv(object scratchWorkspace = null, object tinSaveVersion = null, object workspace = null)
        {
            base.SetEnv(scratchWorkspace: scratchWorkspace, tinSaveVersion: tinSaveVersion, workspace: workspace);
            return this;
        }

    }

}